<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>
<%@ page import="be.ac.ua.ecampus.uacmat.entity.*" %>
<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8" />
        <meta name="viewport" content="width=device-width, initial-scale=1" />
        <title>Course Material
        </title>
        <link rel="stylesheet" href="http://code.jquery.com/mobile/1.1.0/jquery.mobile-1.1.0.min.css" />
        <link rel="stylesheet" href="my.css" />
        <style>
            /* App custom styles */
        </style>
        <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js">
        </script>
        <script src="http://code.jquery.com/mobile/1.1.0/jquery.mobile-1.1.0.min.js">
        </script>
</head>

<body>
<div data-role="page" id="browse">
            <div data-theme="a" data-role="header" data-position="fixed">
                <h3>
                    Course Material
                </h3>
                <div data-role="navbar" data-iconpos="left">
                    <ul>
                        <li>
                            <a href="/uacmat20/index.jsp" data-theme="a" data-icon="search">
                                Search
                            </a>
                        </li>
                        <li>
                            <a href="/uacmat20/browse.jsp" data-theme="b" data-icon="grid" class="ui-btn-active">
                                Browse
                            </a>
                        </li>
                        <li>
                            <a href="/uacmat20/about.jsp" data-theme="a" data-icon="info">
                                About
                            </a>
                        </li>
                    </ul>
                </div>
            </div>
            
            <p><strong><font color="#7e002f">Course:</font></strong></p>
            <% final Course course = (Course) request.getAttribute("course"); %>            
            <p><strong><%= course.getDescription() %></strong></p>
	
			<font color="#7e002f">Syllabuses:</font>
			<ul>
			<% for (final Syllabus result : course.getSyllabuses()) { %>
	 		   <li>
	  		      <a href="/uacmat20/show?type=<%= result.getType() %>&id=<%= result.getId() %>"><%= result.getDescription() %></a>	        
				</li>
			<% } %>
			</ul>
	
		<font color="#7e002f">Programs:</font>
			<ul>
			<% for (final Program result : course.getPrograms()) { %>
	  		  <li>
	   		     <a href="/uacmat20/show?type=<%= result.getType() %>&id=<%= result.getId() %>"><%= result.getDescription() %></a>	        
				</li>
			<% } %>
			</ul>
	    
		<div data-theme="a" data-role="footer" data-position="fixed">
                <h3>
                <INPUT TYPE="BUTTON" VALUE="Go Back" ONCLICK="history.go(-1)">
                </h3>
            </div>
</div>
        
</body>
</html>